package com.ticket.system.service.impl;

import java.util.List;
import com.ticket.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ticket.system.mapper.YuanchuRefundBackendOrderDetailMapper;
import com.ticket.system.domain.YuanchuRefundBackendOrderDetail;
import com.ticket.system.service.IYuanchuRefundBackendOrderDetailService;

/**
 * 出票退款明细Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-02-19
 */
@Service
public class YuanchuRefundBackendOrderDetailServiceImpl implements IYuanchuRefundBackendOrderDetailService 
{
    @Autowired
    private YuanchuRefundBackendOrderDetailMapper yuanchuRefundBackendOrderDetailMapper;

    /**
     * 查询出票退款明细
     * 
     * @param id 出票退款明细主键
     * @return 出票退款明细
     */
    @Override
    public YuanchuRefundBackendOrderDetail selectYuanchuRefundBackendOrderDetailById(Long id)
    {
        return yuanchuRefundBackendOrderDetailMapper.selectYuanchuRefundBackendOrderDetailById(id);
    }

    /**
     * 查询出票退款明细列表
     * 
     * @param yuanchuRefundBackendOrderDetail 出票退款明细
     * @return 出票退款明细
     */
    @Override
    public List<YuanchuRefundBackendOrderDetail> selectYuanchuRefundBackendOrderDetailList(YuanchuRefundBackendOrderDetail yuanchuRefundBackendOrderDetail)
    {
        return yuanchuRefundBackendOrderDetailMapper.selectYuanchuRefundBackendOrderDetailList(yuanchuRefundBackendOrderDetail);
    }

    /**
     * 新增出票退款明细
     * 
     * @param yuanchuRefundBackendOrderDetail 出票退款明细
     * @return 结果
     */
    @Override
    public int insertYuanchuRefundBackendOrderDetail(YuanchuRefundBackendOrderDetail yuanchuRefundBackendOrderDetail)
    {
        yuanchuRefundBackendOrderDetail.setCreateTime(DateUtils.getNowDate());
        return yuanchuRefundBackendOrderDetailMapper.insertYuanchuRefundBackendOrderDetail(yuanchuRefundBackendOrderDetail);
    }

    /**
     * 修改出票退款明细
     * 
     * @param yuanchuRefundBackendOrderDetail 出票退款明细
     * @return 结果
     */
    @Override
    public int updateYuanchuRefundBackendOrderDetail(YuanchuRefundBackendOrderDetail yuanchuRefundBackendOrderDetail)
    {
        return yuanchuRefundBackendOrderDetailMapper.updateYuanchuRefundBackendOrderDetail(yuanchuRefundBackendOrderDetail);
    }

    /**
     * 批量删除出票退款明细
     * 
     * @param ids 需要删除的出票退款明细主键
     * @return 结果
     */
    @Override
    public int deleteYuanchuRefundBackendOrderDetailByIds(Long[] ids)
    {
        return yuanchuRefundBackendOrderDetailMapper.deleteYuanchuRefundBackendOrderDetailByIds(ids);
    }

    /**
     * 删除出票退款明细信息
     * 
     * @param id 出票退款明细主键
     * @return 结果
     */
    @Override
    public int deleteYuanchuRefundBackendOrderDetailById(Long id)
    {
        return yuanchuRefundBackendOrderDetailMapper.deleteYuanchuRefundBackendOrderDetailById(id);
    }
}
